const mongoose = require('mongoose');
// 创建商品表结构
const itemSchema = new mongoose.Schema({
  itemName: {
    type: String,
    required: true
  },
  itemPrice: {
    type: Number,
    required: true
  },
  itemDesc: String,
  sale: {
    type: Number,
    default: 0
  },
  createAt: {
    type: String,
    required: true
  },
  thumb: String,
  content: String
})

const itemModel = mongoose.model('qf_items', itemSchema);

module.exports = itemModel;